<template>
    <div>
       <el-button @click="handlerTest1" >请求1</el-button>
       <el-button @click="handlerTest2">请求2</el-button>

    </div>
</template>

<script>
    import Vue from 'vue'
    import testApi from '@/api/test'
    export default {
        name: "",
        data() {
            return {}
        },
        methods: {
            handlerTest1() {
                testApi.doHello1().then(result => {
                    console.log(result,"======1======")
                }).catch(error=> {
                    console.log(error,"=============")
                });
            },
            handlerTest2() {
                testApi.doHello333({"test":"test"}).then(result => {
                    console.log(result,"222222")
                });
                // this.$MessageN.success()
                // // let st = await testApi.doHello2();
                // testApi.doHello3();
            },
             handleTest3() {
                 let str1 = {test:22};
                 let obj = { handleError: true, headers: {"Content-Type": "multipart/form-data"},...str1};
                 console.log(obj,"----------")
            }
        }
    }
</script>

<style scoped lang="less">
</style>